package com.kingstar.ceres.data;

import com.kingstar.ceres.data.load.FileMappingResourceLoad;
import com.kingstar.ceres.data.properties.FileParsePropertiesWrapper;
import com.kingstar.ceres.data.strategy.DataInitFactory;
import org.springframework.boot.autoconfigure.AutoConfigureBefore;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
@EnableConfigurationProperties(FileParsePropertiesWrapper.class)
@AutoConfigureBefore(CsvImportAutoConfigure.class)
public class KsDataConfiguration {

    @Bean
    public DataInitFactory dataInitFactory(){
        return new DataInitFactory();
    }

    @Bean
    FileMappingResourceLoad resourceLoad(){
        return new FileMappingResourceLoad();
    }
}
